<?php

namespace App\Repositories;

use App\Exceptions\BasicException;
use Illuminate\Support\Facades\Hash;
use function Matrix\add;    //引入hash

class GameJackpotPlanRepository {

    /**
     * 获取奖池方案列表
     * @param $type
     * @return bool
     */
    public function getPlanList($type) {
        $getPlanList = app('model_game_jackpot_plan')->where('type',$type)->get()->toArray();
        return $getPlanList;
    }

    /*
     * 新增奖池方案
     * @param $param
     * @return bool
     * @throws BasicException
     *
     * */
    public function addNewPlan($param) {
        $addNewPrize = app('model_game_jackpot_plan')->create($param);
        if ($addNewPrize) return $addNewPrize;
        throw new BasicException(93070);
    }

}


?>